import requests,unittest
from one.Day3.Tools import Tools
from ddt import data,unpack,ddt,file_data

path = r"C:\Users\HP\Desktop\table.xlsx"
sheetname = 'Sheet1'
dy = Tools(path, sheetname)
print(dy.getdata())

@ddt()
class A3mall(unittest.TestCase):
    token=None
    #登录 login

    @file_data('data.yaml')
    def test_01_login(self,username,password):
        login=requests.post(url='http://10.59.9.14:7003/api/public/login',
                                json={'username': username , 'password': password})
        print(login.json())


if __name__ == '__main__':
    unittest.main()